package cn.dingdan.sercice.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import cn.dingdan.dao.DishesDao;
import cn.dingdan.pojo.Dishes;
import cn.dingdan.sercice.DishesService;
import cn.dingdan.tools.PageSupport;

@Service("dishesServiceImpl")
public class DishesServiceImpl  implements DishesService{
	
	@Resource(name="dishesDao")
	private DishesDao dishesDao;
	
	@Override
	public List<Dishes> getLists(Integer menuTypeId,PageSupport page) {
		return dishesDao.getLists(menuTypeId,page);
	}

	@Override
	public int addDishes(Dishes dishes) {
		return dishesDao.addDishes(dishes);
	}

	@Override
	public int updateDishes(Dishes dishes) {
		return dishesDao.updateDishes(dishes);
	}

	@Override
	public int delDishes(Integer menuId) {
		return dishesDao.delDishes(menuId);
	}

	@Override
	public int getDishesSize(Integer menuTypeId) {
		return dishesDao.getDishesSize(menuTypeId);
	}

	
	public List<Dishes> getInDishesList(String inName) {
		return dishesDao.getInDishesList(inName);
		
	}

	@Override
	public List<Dishes> getEachDishes(List<Integer> list) {
		return dishesDao.getEachDishes(list);
	}

}
